//完整引入element-plus资源
import 'element-plus/dist/index.css'
import ElementPlus from 'element-plus'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'

import { createApp } from 'vue'
import pinia from './stores'

import App from './App.vue'
import router from './router'

//初始化esri的apikey
import esriConfig from '@arcgis/core/config.js'
esriConfig.apiKey =
  'AAPT3NKHt6i2urmWtqOuugvr9bHKfcdr0myQ818HxvrGG3OIldvD3UyNNID7AuBFx_qzZk8Hc88k8TYCNBV7rvr24eJt0Gdx8bAoyalaSFY6jORDNfdvTyUh-ucCc5eEpXNq_2xv18G0_FvFyHulRh91mbDUuLXlCJb2Cm8KrBTlhciJ4Owr5gYHHTk79zjU6Bfu_pzW7I31pafbzm-0MteNP-lqhGC6SDdXwrtiqjZAOjYRci_7y57NdgVrhlB59MIi'
//初始化esri语言
import * as intl from '@arcgis/core/intl.js'
intl.setLocale('zh-CN')

const app = createApp(App)
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}
app.use(ElementPlus)
app.use(pinia)
app.use(router)

app.mount('#app')
